<div class="breadcrumbs">
    <a href="<?php echo base_url(); ?>">Home</a> &raquo; <a href="<?php echo base_url($controller); ?>"><?php echo $controller; ?>s</a>
    <?php
        if ($action == 'view' && $data_id != '') {
            echo " &raquo; <span>$data_id</span>";
        } elseif ($controller == 'line' && $action != 'view' && $data_id != '') {
            echo " &raquo; <a href=\"".base_url('line/view/'.$data_id)."\">$data_id</a> &raquo; <span>$action</span>";
        } elseif ($action != 'view' && $data_id != '') {
            echo " &raquo; <a href=\"\">$data_id</a> &raquo; <span>$action</span>";
        } else {
            echo " &raquo; <span>$action</span>";
        }
    ?>
</div>